#include "ValueFunctionResponseMessage.h"

namespace messaging{

ValueFunctionResponseMessage::ValueFunctionResponseMessage(void)
:GenericMessage(KAgent, KBenchmark, KAgentQueryValuesForObs, KStringList)
{
}

ValueFunctionResponseMessage::~ValueFunctionResponseMessage(void)
{
}


string ValueFunctionResponseMessage::makeMessage()
{
	char* tmpStr = new char [10]; 

	sprintf(tmpStr, "%d:", values.size()); 
	content.append(tmpStr); 

	for(int i=0; i< values.size()-1; i++)
	{
		sprintf(tmpStr, "%3.3lf:", values[i]); 
		content.append(tmpStr); 
	}
		sprintf(tmpStr, "%3.3lf", values[values.size()-1]); 
		content.append(tmpStr); 


	delete tmpStr; 
	return GenericMessage::makeMessage(); 
}
}
